package com.fand.template.utils;

import com.fand.template.support.TemplateSupport;

/**
 * 模板引擎工具类
 * 
 * @author yaoHT
 */
public class TemplateUtils {
	private static TemplateSupport templateSupport;

	/**
	 * 渲染模板字符串
	 * 
	 * @param templateString
	 *            模板字符串
	 * @param model
	 *            映射对象
	 * @return 字符串
	 */
	public static String processString(final String templateString, final Object model) {
		return TemplateUtils.templateSupport.processString(templateString, model);
	}

	public void setTemplateSupport(final TemplateSupport templateSupport) {
		TemplateUtils.templateSupport = templateSupport;
	}
}
